<?php
// 声明命名空间
namespace app\admin\controller;

// 调用控制器
use think\Session;

/**
 * 首页Index类
 */
class Index extends Base{
	
	public function index(){
	    $this->isLogin();
        if(!function_exists('apache_get_version')){
            function apache_get_version(){
                if(!isset($_SERVER['SERVER_SOFTWARE']) || strlen($_SERVER['SERVER_SOFTWARE']) == 0){
                    return false;
                }
                return $_SERVER["SERVER_SOFTWARE"];
            }
        }
	    $ip = $_SERVER['SERVER_NAME'].'[ '.$_SERVER['HTTP_HOST'].' ]';
		$this->assign('site_title','首页-管理后台-百步园艺');
		$this->assign('system',php_uname());
		$this->assign('server',php_sapi_name());
		$this->assign('apache',apache_get_version());
		$this->assign('ip',$ip);
		$this->assign('max',get_cfg_var ("upload_max_filesize"));
		$this->assign('ip_addr',$_SERVER['SERVER_ADDR']);
		$this->assign('time',date("Y年m月d日 H:i:s"));
		return $this->fetch('index');
	}

}